<template>
	<view>
		111
		<u-grid :border="false" @click="click" col="5">
			<u-grid-item v-for="(baseListItem, baseListIndex) in baseList" :key="baseListIndex">
				<u-icon :customStyle="{ paddingTop: 20 + 'rpx' }" :name="baseListItem.name" :size="22"></u-icon>
				<text class="grid-text">{{ baseListItem.title }}</text>
			</u-grid-item>
		</u-grid>
		<u-toast ref="uToast" />
	</view>
</template>

<script>
import {fetchMenu} from '@/common/api.js';
export default {
	data() {
		return {
			baseList: [
				{
					name: 'photo',
					title: '图片'
				},
				{
					name: 'lock',
					title: '锁头'
				},
				{
					name: 'star',
					title: '星星'
				},
				{
					name: 'photo',
					title: '图片'
				},
				{
					name: 'lock',
					title: '锁头'
				},
				{
					name: 'star',
					title: '星星'
				},
				{
					name: 'photo',
					title: '图片'
				},
				{
					name: 'lock',
					title: '锁头'
				},
				{
					name: 'star',
					title: '星星'
				}
			]
		};
	},
	methods: {
		click(name) {
			console.log("点击")
			uni.$u.http.post('/Organization/GrpcDepartment/GetById').then(res=>{
				console.log('数据请求11', res);
			})
			fetchMenu().then(res => {
				console.log('数据请求', res);
			});
		}
	}
};
</script>

<style lang="scss">
.grid-text {
	font-size: 14px;
	color: #909399;
	padding: 10rpx 0 20rpx 0rpx;
	/* #ifndef APP-PLUS */
	box-sizing: border-box;
	/* #endif */
}
</style>
